package com.example.alienware.layout610ly;

import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;

/**
 * Created by Alienware on 2017/5/14.
 */

public class Relativelayout1 extends AppCompatActivity implements View.OnClickListener {

        @Override
        protected void onCreate(Bundle savedInstanceState) {
            super.onCreate(savedInstanceState);
            setContentView(R.layout.relativelayout1);
            Button btn6 = (Button) findViewById(R.id.button6);
            btn6.setOnClickListener(this);
        }

    public void onClick(View v) {
        switch (v.getId()) {

            case R.id.button6:
                Intent intent=new Intent(Relativelayout1.this,MainActivity.class);
                startActivity(intent);
                break;
        }
    }
    }
